<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<script type="text/javascript">
function addNewUploadFrame(){
	var usize=$("#upload-main .fm .cnt").size();
	$("#upload-main").append("<div id=\""+(usize+1)+"\" class=\"fm\">"+$("#upload-main #u1").html().replace("\"f"+usize+"\"","\"f"+(usize+1)+"\"").replace("s_index=1","s_index="+(usize+1))+"</div>");
}
function delUploadFrame(obj){
	if(obj.parentNode.parentNode.parentNode.id!="u1")
		obj.parentNode.parentNode.remove();
}
</script>
<style type="text/css">
#upload-main{
	width:580px;
	margin:0 auto;
}
#upload-main .fm{
	width:570px;
}
#upload-main .fm .cnt{
	width:570px;
	float:left;
	height:auto;
}
#upload-main .fm .cnt .left{
	float:left;
	width:400px;
}
#upload-main .fm .cnt .right{
	float:left;
	width:160px;
}
</style>
<div id="upload-main">
<div id="u1" class="fm">
	<div class="cnt">
		<div class="left">
			<iframe style="scroll:none;"  id="f1" border="0" width="400px" height="80px" src="<%=basePath %>manage/upload/index.do?s_type=periodical&s_dir=<%=request.getParameter("s_dir") %>&s_index=1"></iframe>
		</div>
		<div class="right">
			<input type="button" onclick="addNewUploadFrame()" value="添加图片上传"/>
			<input type="button" onclick="delUploadFrame(this)" value="删除"/>
		</div>
	</div>
</div>
</div>